package com.fxf.srb.core.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fxf.srb.core.pojo.entity.Borrower;
import com.baomidou.mybatisplus.extension.service.IService;
import com.fxf.srb.core.pojo.vo.BorrowerApprovalVO;
import com.fxf.srb.core.pojo.vo.BorrowerDetailVO;
import com.fxf.srb.core.pojo.vo.BorrowerVO;

/**
 * <p>
 * 借款人 服务类
 * </p>
 *
 * @author fxf
 * @since 2021-05-26
 */
public interface IBorrowerService extends IService<Borrower> {

    /**
     * 保存借款人信息
     * @param borrowerVO
     * @param userId
     */
    void saveBorrowerVOByUserId(BorrowerVO borrowerVO, Long userId);

    /**
     * 获取借款人状态
     * @param userId
     * @return
     */
    Integer getBorrowerStatus(Long userId);

    IPage<Borrower> listPage(Page<Borrower> pageParam,String keyword);

    /**
     * 根据id查询借款人详细信息
     * @param id
     * @return
     */
    BorrowerDetailVO getBorrowerDetailsVoById(Long id);

    void approavl(BorrowerApprovalVO borrowerApprovalVO);
}
